<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>设为桌面图标</title>
	</head>
	<body>

		<%
			String filename = request.getSession().getServletContext()
					.getRealPath("/淘助手_智能推广.url");
			String filenamesub = "淘助手_智能推广.url";
			java.io.BufferedInputStream bis = null;
			java.io.BufferedOutputStream bos = null;
			try {
				response.setContentType("application/x-msdownload");
				response.setHeader("Content-disposition",
						"attachment; filename="
								+ new String(filenamesub.getBytes("gb2312"),
										"iso8859-1"));
				bis = new java.io.BufferedInputStream(
						new java.io.FileInputStream(filename));
				bos = new java.io.BufferedOutputStream(response
						.getOutputStream());
				byte[] buff = new byte[2048];
				int bytesRead;
				while (-1 != (bytesRead = bis.read(buff, 0, buff.length))) {
					bos.write(buff, 0, bytesRead);
				}
			} catch (Exception e) {
				e.printStackTrace();
			} finally {
				if (bis != null)
					bis.close();
				if (bos != null)
					bos.close();
				out.clear();
				out = pageContext.pushBody();
			}
		%>
	</body>
</html>